# -*- coding: utf-8 -*-

# __date:       2021/6/10
# __author:     YangChao
# __function:

from core.instrument import SpectrumAnalyzer


if __name__ == '__main__':
    RF = 4.83e9
    LO = 4.8e9
    IF = abs(RF - LO)
    if RF > LO:
        SB = LO - IF
    else:
        SB = LO + IF
    ana = SpectrumAnalyzer()
    ana.config_default(RF, LO, SB)
    l = ana.local_leak()
    print('本振泄露指标为：', l)
    b = ana.sideband_leak()
    print('边带泄露指标为：', b)